import { createRouter, createWebHashHistory, type RouteRecordRaw } from 'vue-router'

const routes = [
  {
    path: '/',
    redirect: '/layout',
  },
  {
    path: '/layout',
    name: 'layout',
    component: () => import('@/components/layout/index.vue'),
    children: [],
  },
  {
    path: '/login',
    name: 'login',
    component: () => import('@/views/login/Login.vue'),
  },
  // {
  //   path: '/register',
  //   component: () => import('./src/views/Register.vue'),
  // },
  {
    path: '/:pathMatch(.*)*',
    component: () => import('@/views/not-found/NotFound.vue'),
  },
]

const router = createRouter({
  history: createWebHashHistory(),
  routes,
})

export default router
